home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1993 April: Penguin on DISC / ADC Developer CD (1993-04) (''Penguin On DISC'')_iso / Dev.CD Apr 93.iso / Utilities / MPW Interfaces 7.1 Beta / AIncludes / ScriptEqu.a < prev    next >
Encoding:
Text File  |  1992-08-28  |  53.9 KB  |  1,572 lines  |  [TEXT/MPS ]

  1. ; Version: 3.18
  2. ; Created: Friday, October 20, 1989 at 9:46:43 PM
  3. ;
  4. ; File ScriptEqu.a
  5. ;
  6. ; Assembler Interface to the Macintosh Libraries
  7. ; Copyright Apple Computer, Inc. 1986-1991
  8. ; All Rights Reserved
  9.  
  10. ;*** Warning: This is an alpha version of the Interfaces for Cube-E. 
  11. ;***          Things may change.  Caveat Programmer.
  12.  
  13.  
  14.     IF &TYPE('__INCLUDINGSCRIPTEQU__') = 'UNDEFINED' THEN
  15. __INCLUDINGSCRIPTEQU__    SET    1
  16.  
  17. ; -----------------------------------------------------------------------------
  18.  
  19. ; Script System constants.
  20.  
  21. smSystemScript    EQU            -1                        ; designates system script                <23>
  22. smCurrentScript    EQU            -2                        ; designates current font script        <27><33>
  23. smAllScripts    EQU            -3                        ; designates any script                    <39>
  24.  
  25. smRoman           EQU         0                         ; Roman
  26. smJapanese        EQU         1                         ; Japanese
  27. smTradChinese     EQU         2                         ; Traditional Chinese                    <14>
  28. smKorean          EQU         3                         ; Korean
  29. smArabic          EQU         4                         ; Arabic
  30. smHebrew          EQU         5                         ; Hebrew
  31. smGreek           EQU         6                         ; Greek
  32. smCyrillic        EQU            7                        ; Cyrillic                                <3>
  33. smRSymbol         EQU         8                         ; Right-left symbols
  34. smDevanagari      EQU         9                         ; Devanagari
  35. smGurmukhi        EQU         10                        ; Gurmukhi
  36. smGujarati        EQU         11                        ; Gujarati
  37. smOriya           EQU         12                        ; Oriya
  38. smBengali         EQU         13                        ; Bengali
  39. smTamil           EQU         14                        ; Tamil
  40. smTelugu          EQU         15                        ; Telugu
  41. smKannada         EQU         16                        ; Kannada/Kanarese
  42. smMalayalam       EQU         17                        ; Malayalam
  43. smSinhalese       EQU         18                        ; Sinhalese
  44. smBurmese         EQU         19                        ; Burmese
  45. smKhmer           EQU         20                        ; Khmer/Cambodian
  46. smThai            EQU         21                        ; Thai
  47. smLaotian         EQU         22                        ; Laotian
  48. smGeorgian        EQU         23                        ; Georgian
  49. smArmenian        EQU         24                        ; Armenian
  50. smSimpChinese   EQU         25                        ; Simplified Chinese                    <14>
  51. smTibetan         EQU         26                        ; Tibetan
  52. smMongolian       EQU         27                        ; Mongolian
  53. smGeez            EQU            28                        ; Geez/Ethiopic                            <1.6>
  54. smEthiopic        EQU            28                        ; Synonym for smGeez                    <20>
  55. smEastEurRoman    EQU         29                        ; Extended Roman for Slavic & Baltic langs    <21>
  56. smVietnamese      EQU         30                        ; Extended Roman for Vietnamese
  57. smExtArabic        EQU            31                        ; Extended Arabic for Sindhi, etc.        <21>
  58. smUninterp        EQU         32                        ; uninterpreted symbols, e.g. palette symbols
  59.  
  60. ; Obsolete names for script systems (kept for backward compatibility).
  61.  
  62. smChinese         EQU         2                         ; (use smTradChinese or smSimpChinese).    <14>
  63. smRussian        EQU            7                        ; (old name for smCyrillic).
  64. ;smMaldivian       EQU         25                        ; (no more smMaldivian!)                <14>
  65. smAmharic        EQU            28                        ; (old name for smGeez)
  66. smSlavic          EQU         29                        ; (old name for smEastEurRoman)
  67. smSindhi          EQU         31                        ; (old name for smExtArabic)            <21>
  68.  
  69. ; Language codes - moved to LanguageEqu.a                                                    <21>
  70.  
  71. ; Calendar Codes
  72.  
  73. calGregorian      EQU         0
  74. calArabicCivil    EQU         1
  75. calArabicLunar    EQU         2
  76. calJapanese       EQU         3
  77. calJewish         EQU         4
  78. calCoptic         EQU         5
  79. calPersian        EQU            6                        ;                                            <19> 
  80.  
  81. ; Integer Format Codes
  82.  
  83. intWestern        EQU         0
  84. intArabic         EQU         1
  85. intRoman          EQU         2
  86. intJapanese       EQU         3
  87. intEuropean       EQU         4
  88. intOutputMask     EQU         $8000
  89.  
  90. ; CharByte byte types.
  91.  
  92. smSingleByte      EQU         0
  93. smFirstByte       EQU         -1
  94. smLastByte        EQU         1
  95. smMiddleByte      EQU         2
  96.  
  97. ; CharType field masks
  98.  
  99. smcTypeMask            EQU        $000F
  100. smcReserved            EQU        $00F0
  101. smcClassMask        EQU        $0F00
  102. smcOrientationMask     EQU        $1000                    ; two-byte script glyph orientation            <27><33>
  103. smcRightMask        EQU        $2000
  104. smcUpperMask        EQU        $4000
  105. smcDoubleMask        EQU        $8000
  106.  
  107. ; Basic CharType character types.
  108.  
  109. smCharPunct       EQU         $0000
  110. smCharAscii       EQU         $0001
  111. smCharEuro        EQU         $0007
  112. smCharExtAscii    EQU         $0007                    ; More correct synonym for smCharEuro        <20>
  113.  
  114. ; Additional CharType character types for script systems.
  115.  
  116. smCharKatakana         EQU     $0002                     ; Japanese Katakana                            <32>
  117. smCharHiragana         EQU     $0003                     ; Japanese Hiragana                            <32>
  118. smCharIdeographic    EQU     $0004                     ; Hanzi, Kanji, Hanja                        <32>
  119. smCharTwoByteGreek    EQU     $0005                     ; 2-byte Greek in Far East systems            <32>
  120. smCharTwoByteRussian EQU     $0006                     ; 2-byte Cyrillic in Far East systems        <32>
  121. smCharBidirect        EQU        $0008                    ; Arabic, Hebrew                            <20>
  122. smCharContextualLR    EQU        $0009                    ; Contextual left-right: Thai, Indic scripts    <48>
  123. smCharNonContextualLR EQU    $000A                    ; Non-contextual left-right: Cyrillic, Greek    <48>
  124. smCharHangul        EQU     $000C                     ; Korean Hangul                                <20><32>
  125. smCharJamo            EQU     $000D                     ; Korean Jamo                                <35>
  126. ; old names for above, for backward compatibility
  127. smCharFISKana         EQU     $0002                     ; Katakana
  128. smCharFISGana         EQU     $0003                     ; Hiragana
  129. smCharFISIdeo         EQU     $0004                     ; Hanzi, Kanji, Hanja
  130. smCharFISGreek        EQU     $0005                     ; 2-byte Greek in Far East systems
  131. smCharFISRussian    EQU     $0006                     ; 2-byte Cyrillic in Far East systems
  132.  
  133. ; CharType punctuation sub-types.
  134.  
  135. smPunctNormal     EQU         $0000
  136. smPunctNumber     EQU         $0100
  137. smPunctSymbol     EQU         $0200
  138. smPunctBlank      EQU         $0300                     ; NBSP is PunctNormal
  139.  
  140. ; CharType punctuation sub-types for two-byte systems                                            <27>
  141.  
  142. smPunctRepeat     EQU         $0400                     ; repeat marker                                <27><32><33>
  143. smPunctGraphic     EQU         $0500                     ; line graphics                                <27><32>
  144.  
  145. ; CharType Katakana and Hiragana sub-types for two-byte systems                                    <27>
  146.  
  147. smKanaSmall        EQU         $0100                     ; small kana character                        <27>
  148. smKanaHardOK    EQU         $0200                     ; can have dakuten                            <27>
  149. smKanaSoftOK    EQU         $0300                     ; can have dakuten or han-dakuten            <27>
  150.  
  151. ; CharType Ideographic sub-types for two-byte systems
  152.  
  153. smIdeographicLevel1    EQU     $0000                     ; level 1 char                                <32>
  154. smIdeographicLevel2    EQU     $0100                     ; level 2 char                                <32>
  155. smIdeographicUser    EQU     $0200                     ; user char                                    <32>
  156. ; old names for some of above, for backward compatibility
  157. smFISClassLvl1    EQU         $0000                     ; level 1 char                                <5><26>
  158. smFISClassLvl2    EQU         $0100                     ; level 2 char                                <5><26>
  159. smFISClassUser    EQU         $0200                     ; user char                                    <5><26>
  160.  
  161. ; CharType Jamo sub-types for Korean systems                                                    <35>
  162.  
  163. smJamoJaeum        EQU         $0000                     ; simple consonant char                        <35>
  164. smJamoBogJaeum    EQU         $0100                     ; complex consonant char                    <35>
  165. smJamoMoeum        EQU         $0200                     ; simple vowel char                            <35>
  166. smJamoBogMoeum    EQU         $0300                     ; complex consonant char                    <35>
  167.  
  168. ; CharType glyph orientation for two-byte systems                                                <27>
  169.  
  170. smCharHorizontal    EQU        $0000                    ; horizontal character form, or for both    <27>
  171. smCharVertical        EQU        $1000                    ; vertical character form                    <27>
  172.  
  173. ; CharType directions
  174.  
  175. smCharLeft        EQU         $0000
  176. smCharRight       EQU         $2000
  177.  
  178. ; CharType case modifers.
  179.  
  180. smCharLower       EQU         $0000
  181. smCharUpper       EQU         $4000
  182.  
  183. ; CharType character size modifiers (1 or multiple bytes).
  184.  
  185. smChar1byte       EQU         $0000
  186. smChar2byte       EQU         $8000
  187.  
  188. ; Char2Pixel directions.
  189.  
  190. smLeftCaret       EQU         0                         ; Place caret for left block.
  191. smRightCaret      EQU         -1                        ; Place caret for right block.
  192. smHilite          EQU         1                         ; Direction is TESysJust.
  193.  
  194. ; Transliterate target types for Roman.
  195.  
  196. smTransAscii      EQU         0                         ; convert to ASCII
  197. smTransNative     EQU         1                         ; convert to font script                <33>
  198. smTransCase       EQU         $FE                       ; convert case for all text
  199. smTransSystem     EQU         $FF                       ; convert to system script
  200.  
  201. ; Transliterate target types for two-byte scripts                                            <35>
  202.  
  203. smTransAscii1     EQU         2                         ; 1-byte Roman
  204. smTransAscii2     EQU         3                         ; 2-byte Roman
  205. smTransKana1      EQU         4                         ; 1-byte Japanese Katakana
  206. smTransKana2      EQU         5                         ; 2-byte Japanese Katakana
  207. ; (no 1-byte hiragana)
  208. smTransGana2      EQU         7                         ; 2-byte Japanese Hiragana
  209. smTransHangul2        EQU     8                         ; 2-byte Korean Hangul                    <35>
  210. smTransJamo2        EQU     9                         ; 2-byte Korean Jamo                    <35>
  211. smTransBopomofo2    EQU     10                         ; 2-byte Chinese Bopomofo                <35>
  212.  
  213. ; Transliterate target modifiers.
  214.  
  215. smTransLower      EQU         $4000                    ; target becomes lowercase                <33>
  216. smTransUpper      EQU         $8000                    ; target becomes uppercase                <33>
  217.  
  218. ; Transliterate source mask - general.
  219.  
  220. smMaskAll         EQU         $FFFFFFFF                 ; Convert all text
  221.  
  222. ; Transliterate source masks for Roman.
  223.  
  224. smMaskAscii       EQU         $00000001                 ; 2^smTransAscii
  225. smMaskNative      EQU         $00000002                 ; 2^smTransNative
  226.  
  227. ; Transliterate source masks for two-byte scripts.                                            <35>
  228.  
  229. smMaskAscii1      EQU         $00000004                 ; 2^smTransAscii1
  230. smMaskAscii2      EQU         $00000008                 ; 2^smTransAscii2
  231. smMaskKana1       EQU         $00000010                 ; 2^smTransKana1
  232. smMaskKana2       EQU         $00000020                 ; 2^smTransKana2
  233. smMaskGana2       EQU         $00000080                 ; 2^smTransGana2
  234. smMaskHangul2    EQU         $00000100                 ; 2^smTransHangul2                        <35>
  235. smMaskJamo2        EQU         $00000200                 ; 2^smTransJamo2                        <35>
  236. smMaskBopomofo2    EQU         $00000400                 ; 2^smTransBopomofo2                    <35>
  237.  
  238. ; Result values from GetEnvirons, SetEnvirons, GetScript and SetScript calls.
  239.  
  240. smNotInstalled    EQU         0                         ; routine not available in script
  241. smBadVerb         EQU         -1                        ; Bad verb passed to a routine.
  242. smBadScript       EQU         -2                        ; Bad script code passed to a routine.
  243.  
  244. ; Values for script redraw flag                                                                    <23>
  245.  
  246. smRedrawChar    EQU            0                        ; redraw character only
  247. smRedrawWord    EQU            1                        ; redraw entire word (2-byte systems)
  248. smRedrawLine    EQU            -1                        ; redraw entire line (bidirectional systems)
  249.  
  250. ; Result values from StyledLineBreak
  251.  
  252. smBreakWord       EQU         0                         ; could break at word boundary
  253. smBreakChar       EQU         1                         ; had to break at char boundary
  254. smBreakOverflow   EQU         2                         ; text too short, width subtracted
  255.  
  256. ; -----------------------------------------------------------------------------
  257. ; GetEnvirons and SetEnvirons verbs.
  258. ; -----------------------------------------------------------------------------
  259.  
  260. smVersion         EQU         0                         ; Script Manager version number.            <33>
  261. smMunged          EQU         2                         ; Globals change count.
  262. smEnabled         EQU         4                         ; Count of enabled scripts, incl Roman.        <33>
  263. smBidirect        EQU         6                         ; At least one bidirectional script.        <33>
  264. smFontForce       EQU         8                         ; Force font flag.
  265. smIntlForce       EQU         10                        ; Force intl flag.
  266. smForced          EQU         12                        ; Script was forced to system script.        <33>
  267. smDefault         EQU         14                        ; Script was defaulted to Roman script.        <33>
  268. smPrint           EQU         16                        ; Printer action routine.
  269. smSysScript       EQU         18                        ; System script.
  270. smLastScript      EQU         20                        ; Last keyboard script.
  271. smKeyScript       EQU         22                        ; Keyboard script.
  272. smSysRef          EQU         24                        ; System folder refNum.
  273. smKeyCache        EQU         26                        ; Obsolete                                    <33>
  274. smKeySwap         EQU         28                        ; Swapping table handle.                    <33>
  275. smGenFlags        EQU         30                        ; general flags long
  276. smOverride        EQU         32                        ; script override flags
  277. smCharPortion     EQU         34                        ; Ch vs SpExtra proportion
  278. ; New for System 7.0:    <2.4>
  279. smDoubleByte    EQU            36                        ; Flag for double-byte script installed        <2.4>
  280. smKCHRCache        EQU            38                        ; Returns pointer to KCHR cache                <2.6>
  281. smRegionCode    EQU            40                        ; Returns current region code (verXxx)        <3>
  282. smKeyDisabState    EQU            42                        ; Returns current keyboard disable state    <44>
  283.  
  284. ; -----------------------------------------------------------------------------
  285. ; GetScript and SetScript verbs.
  286. ; Note: verbs private to script systems are negative, while
  287. ; those general across script systems are non-negative
  288. ; -----------------------------------------------------------------------------
  289.  
  290. smScriptVersion    EQU         0                         ; Script software version.
  291. smScriptMunged    EQU         2                         ; Script entry changed count.
  292. smScriptEnabled    EQU         4                         ; Script enabled flag.
  293. smScriptRight     EQU         6                         ; Right to left flag.
  294. smScriptJust      EQU         8                         ; Justification flag.
  295. smScriptRedraw    EQU         10                        ; Word redraw flag.
  296. smScriptSysFond    EQU         12                        ; Preferred system font.
  297. smScriptAppFond    EQU         14                        ; Preferred Application font.
  298. smScriptBundle    EQU         16                        ; Beginning of itlb verbs.
  299. smScriptNumber    EQU         16                        ; Script itl0 id.
  300. smScriptDate      EQU         18                        ; Script itl1 id.
  301. smScriptSort      EQU         20                        ; Script itl2 id.
  302. smScriptFlags     EQU         22                        ; Script flags
  303. smScriptToken     EQU         24                        ; Script itl4 id.
  304. smScriptEncoding EQU         26                        ; id of optional itl5, if present.            <22>
  305. smScriptLang      EQU         28                        ; Current language for script
  306. smScriptNumDate    EQU         30                        ; Script Number/Date formats
  307. smScriptKeys      EQU         32                        ; Script KCHR id.
  308. smScriptIcon      EQU         34                        ; ID # of SICN or kcs#/kcs4/kcs8 suite.
  309. smScriptPrint     EQU         36                        ; Script printer action routine.
  310. smScriptTrap      EQU         38                        ; Trap entry pointer.
  311. smScriptCreator    EQU         40                        ; Script file creator.
  312. smScriptFile      EQU         42                        ; Script file name.
  313. smScriptName      EQU         44                        ; Script name.
  314. ; There is a hole here for old Kanji private verbs 46-76
  315.  
  316. ; New for System 7.0:    <1.9>
  317. smScriptMonoFondSize EQU      78                        ; default monospace FOND (hi) & size (lo)
  318. smScriptPrefFondSize EQU      80                        ; preferred FOND (hi) & size (lo)
  319. smScriptSmallFondSize EQU     82                        ; default small FOND (hi) & size (lo)
  320. smScriptSysFondSize EQU       84                        ; default system FOND (hi) & size (lo)
  321. smScriptAppFondSize EQU       86                        ; default application FOND (hi) & size (lo)    <9>
  322. smScriptHelpFondSize EQU       88                        ; default Help Mgr FOND (hi) & size (lo)    <9>
  323. smScriptValidStyles EQU       90                        ; mask of valid styles for script            <18>
  324. smScriptAliasStyle EQU       92                        ; style (set) to use for aliases            <18>
  325.  
  326. ; -----------------------------------------------------------------------------
  327. ; Negative verbs for KeyScript                                                                <13><23>
  328. ; -----------------------------------------------------------------------------
  329.  
  330. smKeyNextScript            EQU        -1            ; Switch to next available script
  331. smKeySysScript            EQU        -2            ; Switch to the system script
  332. smKeySwapScript            EQU        -3            ; Switch to previously-used script                    <19>
  333.  
  334. ; New for System 7.0
  335. smKeyNextKybd            EQU        -4            ; Switch to next keyboard in current keyscript
  336. smKeySwapKybd            EQU        -5            ; Switch to previously-used keyboard in current keyscript
  337.                                             ;    (smKeySwapKybd is not implemented in System 7.0)
  338. smKeyDisableKybds        EQU        -6            ; Disable keyboards not in system or Roman script    <23>
  339. smKeyEnableKybds        EQU        -7            ; Re-enable keyboards for all enabled scripts        <23>
  340.  
  341. ; Not currently implemented in System, may be implemented by script systems                        <19>
  342. ; (Renumbered smKeyNextInputMethod, smKeySwapInputMethod)                                        <23>
  343. smKeyToggleInline        EQU        -8            ; Toggle inline input for current keyscript
  344. smKeyToggleDirection    EQU        -9            ; Toggle default line direction (TESysJust)
  345. smKeyNextInputMethod    EQU        -10            ; Switch to next input method in current keyscript    <23>
  346. smKeySwapInputMethod    EQU        -11            ; Switch to last-used input method in cur keyscript    <23>
  347.  
  348. smKeyDisableKybdSwitch    EQU        -12            ; Disable switching from the current keyboard        <24>
  349.  
  350. smKeySetDirLeftRight    EQU        -15            ; Set default line dir to left-right, align left    <42>
  351. smKeySetDirRightLeft    EQU        -16            ; Set default line dir to right-left, align right    <42>
  352. smKeyRoman                EQU        -17            ; Set keyscript to Roman. Does nothing if Roman-only    <46>
  353.                                             ;    system, unlike KeyScript(smRoman) which forces        <46>
  354.                                             ;    an update to current default keyboard for Roman)    <46>
  355. ; -----------------------------------------------------------------------------
  356. ; Bits in the smScriptFlags word (bits above 7 are non-static)
  357. ; -----------------------------------------------------------------------------
  358.  
  359. smsfIntellCP      EQU         0                         ; script has intelligent cut & paste
  360. smsfSingByte      EQU         1                         ; script has only single bytes
  361. smsfNatCase       EQU         2                         ; native chars have upper & lower case
  362. smsfContext       EQU         3                         ; script is contextual                        <33>
  363. smsfNoForceFont    EQU         4                         ; script will not force characters
  364. smsfB0Digits      EQU         5                         ; script has alternate digits at B0-B9
  365. smsfAutoInit    EQU            6                        ; auto initialize the script                <8>
  366. smsfUnivExt        EQU            7                        ; script is handled by universal extension    <42>
  367. smsfForms         EQU         13                        ; uses contextual forms for letters
  368. smsfLigatures     EQU         14                        ; uses contextual ligatures
  369. smsfReverse       EQU         15                        ; reverses native text, right-left
  370.  
  371. ; -----------------------------------------------------------------------------
  372. ; Bits in the smGenFlags long. First (high-order) byte is set from itlc flags byte.
  373. ; -----------------------------------------------------------------------------
  374. smfShowIcon        EQU            31                        ; show icon even if only one script    
  375. smfDualCaret    EQU            30                        ; use dual caret for mixed direction text
  376. smfNameTagEnab    EQU            29                        ; reserved for internal use                    <16>
  377. smfUseAssocFontInfo    EQU        28                        ; Use the associated font info for FontMetrics calls <45>
  378.  
  379. ; -----------------------------------------------------------------------------
  380. ; Bits in the itlcFlags byte.
  381. ; -----------------------------------------------------------------------------
  382. itlcShowIcon    EQU            7                        ; Show icon even if only one script            <41>    
  383. itlcDualCaret    EQU            6                        ; Use dual caret for mixed direction text    <41>
  384.  
  385. ; -----------------------------------------------------------------------------
  386. ; Bits in the itlcSysFlags word.
  387. ; -----------------------------------------------------------------------------
  388. itlcSysDirection    EQU        15                        ; System direction - left to right/right to left    <41>
  389.  
  390. ; -----------------------------------------------------------------------------
  391. ; Roman script constants.
  392. ; -----------------------------------------------------------------------------
  393.  
  394. ; The following are here for backward compatibility, but should not be used.                    <19>
  395. ; This information should be obtained using GetScript.
  396. romanSysFond    EQU    $3FFF                            ; system font id number.
  397. romanAppFond    EQU    3                                ; application font id number.
  398. romanFlags        EQU    (1<<smsfIntellCP)+(1<<smsfSingByte)+(1<<smsfNatCase)    ; roman settings
  399.  
  400. ; Script Manager font equates.
  401.  
  402. smFondStart       EQU         $4000                     ; start from 16K.
  403. smFondEnd         EQU         $C000                     ; past end of range at 48K.
  404.  
  405. ; -----------------------------------------------------------------------------
  406. ; Simple script constants.
  407. ; -----------------------------------------------------------------------------
  408. smUprHalfCharSet    EQU        $80        ; first character code in upper half of Macintosh Character Set    <8>
  409.  
  410. ; -----------------------------------------------------------------------------
  411. ; Macintosh character set extensions
  412. ; -----------------------------------------------------------------------------
  413.  
  414. diaeresisUprY     EQU         $D9                       ; Ÿ
  415. fraction          EQU         $DA                       ; ⁄
  416. intlCurrency      EQU         $DB                       ; €
  417. leftSingGuillemet    EQU     $DC                       ; ‹
  418. rightSingGuillemet    EQU        $DD                       ; ›
  419. fiLigature        EQU         $DE                       ; fi
  420. flLigature        EQU         $DF                       ; fl
  421. dblDagger         EQU         $E0                       ; ‡
  422. centeredDot       EQU         $E1                       ; ·
  423. baseSingQuote     EQU         $E2                       ; ‚
  424. baseDblQuote      EQU         $E3                       ; „
  425. perThousand       EQU         $E4                       ; ‰
  426. circumflexUprA    EQU         $E5                       ; Â
  427. circumflexUprE    EQU         $E6                       ; Ê
  428. acuteUprA         EQU         $E7                       ; Á
  429. diaeresisUprE     EQU         $E8                       ; Ë
  430. graveUprE         EQU         $E9                       ; È
  431. acuteUprI         EQU         $EA                       ; Í
  432. circumflexUprI    EQU         $EB                       ; Î
  433. diaeresisUprI     EQU         $EC                       ; Ï
  434. graveUprI         EQU         $ED                       ; Ì
  435. acuteUprO         EQU         $EE                       ; Ó
  436. circumflexUprO    EQU         $EF                       ; Ô
  437. appleLogo         EQU         $F0                       ; 
  438. graveUprO         EQU         $F1                       ; Ò
  439. acuteUprU         EQU         $F2                       ; Ú
  440. circumflexUprU    EQU         $F3                       ; Û
  441. graveUprU         EQU         $F4                       ; Ù
  442. dotlessLwrI       EQU         $F5                       ; ı
  443. circumflex        EQU         $F6                       ; ˆ
  444. tilde             EQU         $F7                       ; ˜
  445. macron            EQU         $F8                       ; ¯
  446. breveMark         EQU         $F9                       ; ˘                                        <34>
  447. overDot           EQU         $FA                       ; ˙
  448. ringMark          EQU         $FB                       ; ˚                                        <34>
  449. cedilla           EQU         $FC                       ; ¸
  450. doubleAcute       EQU         $FD                       ; ˝
  451. ogonek            EQU         $FE                       ; ˛
  452. hachek            EQU         $FF                       ; (don't type it here - breaks MPW tools!)
  453.  
  454. ; -----------------------------------------------------------------------------
  455. ; Other new constants for 7.0                                                                <2.7>
  456. ; -----------------------------------------------------------------------------
  457.  
  458. ; Constants for truncWhere argument in TruncString and TruncText                            <2.7>
  459.  
  460. smTruncEnd        EQU         0                         ; Truncate at end
  461. smTruncMiddle     EQU         $4000                     ; Truncate in middle
  462.  
  463. ; Constants for TruncString and TruncText results                                            <13>
  464.  
  465. smNotTruncated     EQU         0                        ; No truncation was necessary
  466. smTruncated        EQU         1                         ; Truncation performed
  467. smTruncErr        EQU            -1                        ; General error
  468.  
  469. ; Constants for styleRunPosition argument in NPortionText, NDrawJust, NMeasureJust,            <2>
  470. ; NChar2Pixel, and NPixel2Char.
  471.  
  472. smOnlyStyleRun    EQU         0                         ; This is the only style run on the line.
  473. smLeftStyleRun    EQU         1                         ; This is leftmost of multiple style runs on the line.
  474. smRightStyleRun   EQU         2                         ; This is rightmost of multiple style runs on the line.
  475. smMiddleStyleRun  EQU         3                         ; There are multiple style runs on the line and this…
  476.                                                     ; …is neither the leftmost nor the rightmost.
  477.  
  478. ; -----------------------------------------------------------------------------
  479. ; Record declarations for itlc, itlb, itl2, itl4
  480. ; -----------------------------------------------------------------------------
  481. ; Record declaration for international configuration resource (type itlc).
  482.  
  483. ItlcRecord        record      0
  484. itlcSystem        ds.w        1                         ; default system script.
  485. itlcReserved      ds.w        1                         ; reserved
  486. itlcFontForce     ds.b        1                         ; default font force flag.
  487. itlcIntlForce     ds.b        1                         ; default intl force flag.
  488. itlcOldKybd       ds.b        1                         ; MacPlus intl keybd flag                <33>
  489. itlcFlags         ds.b        1                         ; general flags
  490. itlcIconOffset    ds.w        1                        ; keyboard icon offset (not in 7.0)        <1.3><33>
  491. itlcIconSide    ds.b        1                        ; keybd icon side (R=0,L=$FF) (not 7.0) <1.3><33>
  492. itlcIconRsvd    ds.b        1                        ; rsvd for other icon info                <1.3><33>
  493. itlcRegionCode    ds.w        1                        ; preferred verXxx code                    <4>
  494. itlcSysFlags    ds.w        1                        ; flags for setting system globals        <40>
  495. itlcReserved4    ds.b        32                        ; for future use                        <4><5><40>
  496. itlcSize          equ         *                         ; size of script itlc.
  497.                   endr
  498.  
  499. ; Record declaration for international bundle resource (type itlb).
  500.  
  501. ItlbRecord        record      0
  502. itlbNumber        ds.w        1                         ; itl0 ID number.
  503. itlbDate          ds.w        1                         ; itl1 ID number.
  504. itlbSort          ds.w        1                         ; itl2 ID number.
  505. itlbFlags         ds.w        1                         ; Script Flags.
  506. itlbToken         ds.w        1                         ; itl4 ID number.
  507. itlbEncoding     ds.w        1                         ; itl5 ID # (optional; char encoding).    <22>
  508. itlbLang          ds.w        1                         ; current language for script
  509. itlbNumRep        ds.b        1                         ; number representation code
  510. itlbDateRep       ds.b        1                         ; date representation code
  511. itlbKeys          ds.w        1                         ; KCHR id number.
  512. itlbIcon          ds.w        1                         ; ID # of SICN or kcs#/kcs4/kcs8 suite.
  513. itlbSize          equ         *                         ; size of bundle.
  514.                   endr
  515.  
  516. ; Extended itlb to support auto initialization of scripts <8>
  517. ItlbExtRecord    record    0
  518. base            ds        ItlbRecord        ; un-extended itlbRecord
  519. itlbLocalSize    ds.l    1                ; size of script's local record
  520. itlbMonoFond    ds.w    1                ; default monospace FOND ID
  521. itlbMonoSize    ds.w    1                ; default monospace font size
  522. itlbPrefFond    ds.w    1                ; preferred FOND ID
  523. itlbPrefSize    ds.w    1                ; preferred font size
  524. itlbSmallFond    ds.w    1                ; default small FOND ID
  525. itlbSmallSize    ds.w    1                ; default small font size
  526. itlbSysFond        ds.w    1                ; default system FOND ID
  527. itlbSysSize        ds.w    1                ; default system font size
  528. itlbAppFond        ds.w    1                ; default application FOND ID
  529. itlbAppSize        ds.w    1                ; default application font size
  530. itlbHelpFond    ds.w    1                ; default Help Mgr FOND ID                            <9>
  531. itlbHelpSize    ds.w    1                ; default Help Mgr font size                        <9>
  532. itlbValidStyles    ds.b    1                ; mask of valid styles for script                    <18>
  533. itlbAliasStyle    ds.b    1                ; style (set) to mark aliases                        <18>
  534. itlbExtSize        equ    *                    ; size of ItlbExtRecord
  535.                 endr
  536.                 
  537. ; itl2 routine vector offsets.
  538.  
  539. initHook          EQU         0
  540. fetchHook         EQU         2
  541. vernierHook       EQU         4
  542. projectHook       EQU         6
  543. rsvdHook          EQU         8
  544. exitHook          EQU         10
  545.  
  546. ; Note that the value of itl2FlagsOffset is equal
  547. ; to the value of rsvdHook. In the old itl2
  548. ; format the value at this location was an 
  549. ; unused routine offset. In the new itl2
  550. ; format, the value at this location is a flag
  551. ; ($ffff) indicating the new format that includes
  552. ; the offsets to the tables for LwrString and
  553. ; tables for the Roman versions of the CharType,
  554. ; Transliterate and FindWord.
  555.  
  556. itl2FlagsOffset   EQU         8
  557. ; itl2 table offsets
  558.  
  559. typeListOffset      EQU         12
  560. classArrayOffset  EQU         14
  561. upperListOffset   EQU         16
  562. lowerListOffset   EQU         18
  563. upperNoMarkListOffset EQU     20
  564. wordTableOffset   EQU         22
  565. wrapTableOffset   EQU         24
  566. noMarkListOffset  EQU         26
  567. itl2VersionOffset EQU         28
  568. itl2FormatOffset  EQU        30        ;                                    <28>
  569.  
  570. ; New for System 7.0:<2.5>
  571. ; itl2 table/code lengths.
  572.  
  573. wordTableLen            EQU    54        ;                                    <2.5>
  574. wrapTableLen            EQU    56        ;                                    <2.5>
  575. findScriptTableOffset    EQU    60        ;                                     <8>
  576. findScriptTableLen        EQU    62        ;                                     <8>
  577.  
  578. ; New for System 7.0:
  579. ; itl2FormatOffset definitions
  580. hdrExtensionsExist    EQU        1        ;                                    <28>
  581.  
  582. ; String data structure for itl2 stack frames.
  583.  
  584. IUStrData         record      0
  585. curChar           ds.w        1                         ; current character.
  586. mapChar           ds.w        1                         ; projected character.
  587. decChar           ds.w        1                         ; decision char for weak equality.
  588. bufChar           ds.b        1                         ; buffer for expansion.
  589. justAfter         ds.b        1                         ; boolean for AE vs ligature-AE.
  590. ignChar           ds.b        1                         ; flag: ignore char.
  591. noFetch           ds.b        1                         ; flag: no fetch of next.
  592. strCnt            ds.w        1                         ; length word.
  593. strPtr            ds.l        1                         ; current ptr to string.
  594.                   endr
  595.  
  596. ; Stack frame for itl2 sorting routines.
  597.  
  598. IUSortFrame       record      {oldA6},decrement
  599. result            ds.w        1
  600. aStrText          ds.l        1
  601. bStrText          ds.l        1
  602. aStrLen           ds.w        1
  603. bStrLen           ds.w        1
  604. return            ds.l        1
  605. oldA6             ds.l        1
  606. aInfo             ds          IUStrData
  607. bInfo             ds          IUStrData
  608. wantMag         ds.b        1                        ; 0 to use primary differences only; else 1        <33>
  609. weakEq            ds.b        1                        ; Signals at most weak equality.
  610. msLock            ds.b        1                        ; (obsolete, not used)
  611. weakMag         ds.b        1                        ; -1 to force magnitude result (-1,0,1); else 0    <33>
  612. supStorage        ds.b        18                        ; extra storage.
  613. weakAPtr          ds.l        1                         ; sup. pointer
  614. weakBPtr          ds.l        1                         ; sup. pointer
  615. lkSize            equ         *                         ; frame size.
  616. paramBytes        equ         aStrText-return
  617.                   endr
  618.  
  619. ; New for System 7.0:
  620. ; New stack frame for itl2 sorting routines in System 7.0; adds itl2Handle field.                    <5>
  621.  
  622. IUNSortFrame record    {oldA6},decrement
  623. result        ds.w    1
  624. aStrText    ds.l    1
  625. bStrText    ds.l    1
  626. aStrLen        ds.w    1
  627. bStrLen        ds.w    1
  628. return        ds.l    1
  629. oldA6        ds.l    1
  630. aInfo        ds    IUStrData
  631. bInfo        ds    IUStrData
  632. wantMag     ds.b    1            ; 0 to use primary differences only; else 1                            <33>
  633. weakEq        ds.b    1            ; Signals at most weak equality.
  634. msLock        ds.b    1            ; (obsolete, not used)
  635. weakMag     ds.b    1            ; -1 to force magnitude result (-1,0,1); else 0                        <33>
  636. supStorage    ds.b    18            ; extra storage.
  637. weakAPtr    ds.l    1            ; sup. pointer
  638. weakBPtr    ds.l    1            ; sup. pointer
  639. itl2Handle    ds.l    1            ; itl2 handle, if supplied                                            <2.3>
  640. lkSize        equ    *                ; frame size.
  641. paramBytes    equ    aStrText-return
  642.             endr
  643.  
  644. Itl4Rec           record      0,increment    ;                                                (added comments <33>)
  645. flags             ds.w        1            ; reserved
  646. resourceType      ds.l        1            ; contains 'itl4'
  647. resourceNum       ds.w        1            ; resource ID
  648. version           ds.w        1            ; version number
  649. resHeader1        ds.l        1            ; reserved
  650. resHeader2        ds.l        1            ; reserved
  651. numTables         ds.w        1            ; number of tables, one-based
  652.                                 ; the following offsets are from beginning of resource
  653. mapOffset         ds.l        1            ; offset to table that maps byte to token
  654. strOffset         ds.l        1            ; offset to routine that copies canonical string
  655. fetchOffset       ds.l        1            ; offset to routine that gets next byte of character
  656. unTokenOffset     ds.l        1            ; offset to table that maps token to canonical string
  657. defPartsOffset    ds.l        1            ; offset to default number parts table
  658. resOffset6        ds.l        1            ; reserved
  659. resOffset7        ds.l        1            ; reserved
  660. resOffset8        ds.l        1            ; reserved
  661. itl4HeaderSize    equ         *
  662. ; the rest is data pointed to by offsets.
  663.                   endr
  664.  
  665. ; New for System 7.0:    <5>
  666.  
  667. NItl4Rec        record    0,increment    ;                                        (added comments <33>)
  668. flags            ds.w    1            ; reserved
  669. resourceType    ds.l    1            ; contains 'itl4'
  670. resourceNum        ds.w    1            ; resource ID
  671. version            ds.w    1            ; version number
  672. format            ds.w    1            ; format code                                <29>
  673. resHeader        ds.w    1            ; reserved                                    <29>
  674. resHeader2        ds.l    1            ; reserved
  675. numTables        ds.w    1            ; number of tables, one-based
  676.                             ; the following offsets are from beginning of resource
  677. mapOffset        ds.l    1            ; offset to table that maps byte to token
  678. strOffset        ds.l    1            ; offset to routine that copies canonical string
  679. fetchOffset        ds.l    1            ; offset to routine that gets next byte of character
  680. unTokenOffset    ds.l    1            ; offset to table that maps token to canonical string
  681. defPartsOffset    ds.l    1            ; offset to default number parts table
  682. whtSpListOffset    ds.l    1            ; offset to white space code list            <2.3><15>
  683. resOffset7        ds.l    1            ; reserved
  684. resOffset8        ds.l    1            ; reserved
  685. resLength1        ds.w    1            ; reserved                                    <2.5>
  686. resLength2        ds.w    1            ; reserved                                    <2.5>
  687. resLength3        ds.w    1            ; reserved                                    <2.5>
  688. unTokenLength    ds.w    1            ; length of untoken table                    <2.5><9>
  689. defPartsLength    ds.w    1            ; length of default number parts table        <2.5><9>
  690. whtSpListLength    ds.w    1            ; length of white space code list            <2.5><9><20>
  691. resLength7        ds.w    1            ; reserved                                    <2.5>
  692. resLength8        ds.w    1            ; reserved                                    <2.5>
  693. nItl4HeaderSize    equ        *            ;                                            <22>
  694. ; the rest is data pointed to by offsets.
  695.             endr
  696.  
  697. ; -----------------------------------------------------------------------------
  698. ; Record declarations and constants for date/time/location handling
  699. ; -----------------------------------------------------------------------------
  700.  
  701. LongDateRec       record      0                         ; zero any fields not used!
  702. era               ds.w        1
  703. year              ds.w        1
  704. month             ds.w        1
  705. day               ds.w        1
  706. hour              ds.w        1
  707. minute            ds.w        1
  708. second            ds.w        1
  709. dayOfWeek         ds.w        1
  710. dayOfYear         ds.w        1
  711. weekOfYear        ds.w        1
  712. pm                ds.w        1
  713. ldReserved        ds.w        3
  714. LongDateRecSize   equ         *
  715.                   endR
  716.  
  717. LongDateTime      record      0                         ; record for comp type
  718. highLong          ds.l        1
  719. lowLong           ds.l        1
  720.                   endR
  721.  
  722. ; date equates constants
  723.  
  724. LongDateField     record      0                         ;DateField: enum type
  725. eraField          ds.b        1
  726. yearField         ds.b        1
  727. monthField        ds.b        1
  728. dayField          ds.b        1
  729. hourField         ds.b        1
  730. minuteField       ds.b        1
  731. secondField       ds.b        1
  732. dayOfWeekField    ds.b        1
  733. dayOfYearField    ds.b        1
  734. weekOfYearField   ds.b        1
  735. pmField           ds.b        1
  736. res1Field         ds.b        1
  737. res2Field         ds.b        1
  738. res3Field         ds.b        1
  739.  
  740. maxDateField      equ         pmField                   ; currently largest used field
  741.  
  742. eraMask           equ         1<<eraField
  743. yearMask          equ         1<<yearField
  744. monthMask         equ         1<<monthField
  745. dayMask           equ         1<<dayField
  746. hourMask          equ         1<<hourField
  747. minuteMask        equ         1<<minuteField
  748. secondMask        equ         1<<secondField
  749. dayOfWeekMask     equ         1<<dayOfWeekField
  750. dayOfYearMask     equ         1<<dayOfYearField
  751. weekOfYearMask    equ         1<<weekOfYearField
  752. pmMask            equ         1<<pmField
  753.  
  754. dateStdMask       equ         eraMask++yearMask++monthMask++dayMask++hourMask++minuteMask++secondMask
  755.                   endR
  756.  
  757. smallDateBit      EQU         31                        ; Restrict valid date/time to range of Time global
  758. togChar12HourBit  EQU         30                        ; If toggling hour by char, accept hours 1..12 only
  759. togCharZCycleBit  EQU         29                        ; Modifier for togChar12HourBit: accept hours 0..11 only
  760. togDelta12HourBit EQU         28                        ; If toggling hour up/down, restrict to 12-hour range (am/pm)
  761. genCdevRangeBit   EQU         27                        ; Restrict date/time to range used by genl CDEV
  762. validDateFields   EQU         -1
  763.  
  764.  
  765. TogglePB          record      0
  766. togFlags         ds.l        1                         ; longint; caller normally sets low word to dateStdMask = $7F
  767. amChars          ds.l        1                         ; ResType; from 'itl0', but uppercased                <33>
  768. pmChars          ds.l        1                         ; ResType; from 'itl0', but uppercased                <33>
  769. reserved         ds.l        4                         ; array [0..3] of Longint
  770.                   endR
  771.  
  772. ToggleResults     record      0
  773. toggleUndefined   ds.b        1
  774. toggleOk          ds.b        1
  775. toggleBadField    ds.b        1
  776. toggleBadDelta    ds.b        1
  777. toggleBadChar     ds.b        1
  778. toggleUnknown     ds.b        1
  779. toggleBadNum      ds.b        1                         ; can't use char as number
  780. toggleOutOfRange  EQU         *                         ; synonym for toggleErr3
  781. toggleErr3        ds.b        1                         ; reserved
  782. toggleErr4        ds.b        1                         ; reserved
  783. toggleErr5        ds.b        1                         ; reserved
  784.                   endR
  785.  
  786. MachineLocation   record      0
  787. latitude          ds.l        1                         ; fract
  788. longitude         ds.l        1                         ; fract
  789. dlsDelta          ds.b        1                         ; signed byte
  790. gmtDelta          ds.b        3                         ; 3 byte signed integer
  791.                   endR
  792.  
  793.  
  794. ; String2Date/String2Time status values
  795.  
  796. fatalDateTime        EQU     $8000                     ; String2Date and String2Time mask to a fatal error
  797. longDateFound        EQU     1                         ; String2Date mask to long date found
  798. leftOverChars        EQU     2                         ; String2Date & Time mask to warn of left over characters
  799. sepNotIntlSep        EQU     4                         ; String2Date & Time mask to warn of non-standard separators
  800. fieldOrderNotIntl    EQU     8                         ; String2Date & Time mask to warn of non-standard field order
  801. extraneousStrings    EQU     16                        ; String2Date & Time mask to warn of unparsable strings in text
  802. tooManySeps            EQU     32                        ; String2Date & Time mask to warn of too many separators
  803. sepNotConsistent    EQU     64                        ; String2Date & Time mask to warn of inconsistent separators
  804. tokenErr            EQU     fatalDateTime + 256       ; String2Date & Time mask for 'tokenizer err encountered'
  805. cantReadUtilities    EQU     fatalDateTime + 512       ;
  806. dateTimeNotFound    EQU     fatalDateTime + 1024      ; String2Date mask for 'date was not found'
  807. dateTimeInvalid        EQU     fatalDateTime + 2048      ; Invalid time/date e.g. 13:61PM
  808.  
  809.  
  810. DateOrders        RECORD      0,INCREMENT
  811. mdy               DS.B        1
  812. dmy               DS.B        1
  813. ymd               DS.B        1
  814. myd               DS.B        1
  815. dym               DS.B        1
  816. ydm               DS.B        1
  817.                   ENDR
  818.  
  819. ; -----------------------------------------------------------------------------
  820. ;  Constants and record declarations for tokenizer                            (added comments <33>)
  821. ; -----------------------------------------------------------------------------
  822.  
  823. tokenIntl         EQU         4             ; the itl resource number for the tokenizer
  824.  
  825. tokenEmpty        EQU         -1            ; used internally as an empty flag
  826. tokenUnknown      EQU         0            ; chars that do not match a defined token type
  827. tokenWhite        EQU         1            ; white space
  828. tokenLeftLit      EQU         2            ; literal begin
  829. tokenRightLit     EQU         3            ; literal end
  830. tokenAlpha        EQU         4            ; alphabetic
  831. tokenNumeric      EQU         5            ; numeric
  832. tokenNewLine      EQU         6            ; new line
  833. tokenLeftComment  EQU         7            ; open comment
  834. tokenRightComment EQU         8            ; close comment
  835. tokenLiteral      EQU         9            ; literal
  836. tokenEscape       EQU         10            ; character escape (e.g. '\' in "\n", "\t")
  837. tokenAltNum       EQU         11            ; alternate number (e.g. $B0-B9 in Arabic,Hebrew)
  838. tokenRealNum      EQU         12            ; real number
  839. tokenAltReal      EQU         13            ; alternate real number
  840. tokenReserve1     EQU         14            ; reserved
  841. tokenReserve2     EQU         15            ; reserved
  842. tokenLeftParen    EQU         16            ; open parenthesis
  843. tokenRightParen   EQU         17            ; close parenthesis
  844. tokenLeftBracket  EQU         18            ; open square bracket
  845. tokenRightBracket EQU         19            ; close square bracket
  846. tokenLeftCurly    EQU         20            ; open curly bracket
  847. tokenRightCurly   EQU         21            ; close curly bracket
  848. tokenLeftEnclose  EQU         22            ; open guillemet
  849. tokenRightEnclose EQU         23            ; close guillemet
  850. tokenPlus         EQU         24
  851. tokenMinus        EQU         25
  852. tokenAsterisk     EQU         26            ; times/multiply
  853. tokenDivide       EQU         27
  854. tokenPlusMinus    EQU         28            ; plus or minus symbol
  855. tokenSlash        EQU         29
  856. tokenBackSlash    EQU         30
  857. tokenLess         EQU         31            ; less than symbol
  858. tokenGreat        EQU         32            ; greater than symbol
  859. tokenEqual        EQU         33
  860. tokenLessEqual2   EQU         34            ; less than or equal, 2 characters (e.g. <=)
  861. tokenLessEqual1   EQU         35            ; less than or equal, 1 character
  862. tokenGreatEqual2  EQU         36            ; greater than or equal, 2 characters (e.g. >=)
  863. tokenGreatEqual1  EQU         37            ; greater than or equal, 1 character
  864. token2Equal       EQU         38            ; double equal (e.g. ==)
  865. tokenColonEqual   EQU         39            ; colon equal
  866. tokenNotEqual     EQU         40            ; not equal, 1 character
  867. tokenLessGreat    EQU         41            ; less/greater, Pascal not equal (e.g. <>)
  868. tokenExclamEqual  EQU         42            ; exclamation equal, C not equal (e.g. !=)
  869. tokenExclam       EQU         43            ; exclamation point
  870. tokenTilde        EQU         44            ; centered tilde                        (fix spelling <15>)
  871. tokenComma        EQU         45
  872. tokenPeriod       EQU         46
  873. tokenLeft2Quote   EQU         47            ; open double quote
  874. tokenRight2Quote  EQU         48            ; close double quote
  875. tokenLeft1Quote   EQU         49            ; open single quote
  876. tokenRight1Quote  EQU         50            ; close single quote
  877. token2Quote       EQU         51            ; double quote
  878. token1Quote       EQU         52            ; single quote
  879. tokenSemicolon    EQU         53
  880. tokenPercent      EQU         54
  881. tokenCaret        EQU         55            ;                                        (fix spelling <33>)
  882. tokenUnderline    EQU         56
  883. tokenAmpersand    EQU         57
  884. tokenAtSign       EQU         58
  885. tokenBar          EQU         59            ; vertical bar
  886. tokenQuestion     EQU         60
  887. tokenPi           EQU         61            ; lower-case pi
  888. tokenRoot         EQU         62            ; square root symbol
  889. tokenSigma        EQU         63            ; capital sigma
  890. tokenIntegral     EQU         64            ; integral sign
  891. tokenMicro        EQU         65
  892. tokenCapPi        EQU         66            ; capital pi
  893. tokenInfinity     EQU         67
  894. tokenColon        EQU         68
  895. tokenHash         EQU         69            ; e.g. #
  896. tokenDollar       EQU         70
  897. tokenNoBreakSpace EQU         71            ; non-breaking space
  898. tokenFraction     EQU         72
  899. tokenIntlCurrency EQU         73
  900. tokenLeftSingGuillemet EQU    74
  901. tokenRightSingGuillemet EQU   75        ;                                    (Fixed spelling <19>)
  902. tokenPerThousand  EQU         76
  903. tokenEllipsis    EQU         77            ;                                            <15>
  904. tokenCenterDot    EQU         78            ;                                            <15>
  905. tokenNil          EQU         127
  906.  
  907. delimPad          EQU         -2
  908.  
  909. ; obsolete, misspelled token names kept for backward compatibility            (moved here <33>)
  910.  
  911. tokenTilda        EQU         44            ; keep wrong spelling for backward compatibility <15>
  912. tokenCarat        EQU         55
  913.  
  914. TokenResults      record      0
  915. tokenOK           ds.b        1
  916. tokenOverflow     ds.b        1
  917. stringOverflow    ds.b        1
  918. badDelim          ds.b        1
  919. badEnding         ds.b        1
  920. crash             ds.b        1
  921.                   endr
  922.  
  923. TokenBlock        RECORD      0,INCR                    ;                                    (added comments <33>)
  924. source            ds.l        1                        ; pointer to stream of characters
  925. sourceLength      ds.l        1                        ; length of source stream
  926. tokenList         ds.l        1                        ; pointer to array of tokens
  927. tokenLength       ds.l        1                        ; maximum length of TokenList
  928. tokenCount        ds.l        1                        ; number tokens generated by tokenizer
  929. stringList        ds.l        1                        ; pointer to stream of identifiers
  930. stringLength      ds.l        1                        ; length of string list
  931. stringCount       ds.l        1                        ; number of bytes currently used
  932. doString          ds.b        1                        ; Boolean: make strings & put into StringList
  933. doAppend          ds.b        1                        ; Boolean: append to TokenList rather than replace
  934. doAlphanumeric    ds.b        1                        ; Boolean: identifiers may include numeric
  935. doNest            ds.b        1                        ; Boolean: do comments nest?
  936. leftDelims        ds.w        2
  937. rightDelims       ds.w        2
  938. leftComment       ds.l        2
  939. rightComment      ds.l        2
  940. escapeCode        ds.w        1                        ; escape symbol code
  941. decimalCode       ds.w        1
  942. itlResource       ds.l        1                        ; handle to itl4 resource of current script
  943. reserved          ds.l        8                         ; must be zero!
  944.                   ENDR
  945.  
  946. TokenRec          RECORD      0,INCR                    ;                                    (added comments <33>)
  947. theToken          ds.w        1                        ; TokenType
  948. position          ds.l        1                        ; Ptr into original source
  949. length            ds.l        1                        ; length of text in original source
  950. stringPosition    ds.l        1                        ; StringPtr to copy of identifier
  951. tokenRecSize      equ         *
  952.                   ENDR
  953.  
  954. UntokenTable      Record      0, INCR
  955. len               ds.w        1
  956. lastToken         ds.w        1
  957. index             ds.w        256                       ; index table; last = lastToken
  958. ;list of pascal strings here. index pointers are from front of table
  959.                   Endr
  960.  
  961. ; -----------------------------------------------------------------------------
  962. ; Record declarations and constants for formatted number handling
  963. ; -----------------------------------------------------------------------------
  964.  
  965. ; FormatClass enumeration
  966.  
  967. fPositive         EQU         0
  968. fNegative         EQU         1
  969. fZero             EQU         2
  970.  
  971. ; FormatResultType enumeration
  972.  
  973. fFormatOK         EQU         0
  974. fBestGuess        EQU         1
  975. fOutOfSynch       EQU         2
  976. fSpuriousChars    EQU         3
  977. fMissingDelimiter EQU         4
  978. fExtraDecimal     EQU         5
  979. fMissingLiteral   EQU         6
  980. fExtraExp         EQU         7
  981. fFormatOverflow   EQU         8
  982. fFormStrIsNAN     EQU         9
  983. fBadPartsTable    EQU         10
  984. fExtraPercent     EQU         11
  985. fExtraSeparator   EQU         12
  986. fEmptyFormatString EQU        13
  987.  
  988. WideChar          record      0,increment
  989. a                 ds.b        2                         ; PACKED ARRAY[0..1] OF CHAR
  990.                   ORG         a
  991. b                 ds.w        1                         ; INTEGER
  992.                   endr
  993.  
  994. WideCharArr       record      0,increment
  995. size              ds.w        1                         ; INTEGER
  996. data              ds.w        10                        ; PACKED ARRAY[0..9] OF WideChar
  997.                   endr
  998.  
  999. fVNumber          EQU         0                         ; first version of NumFormatString
  1000.  
  1001. NumFormatString   record      0,increment
  1002. fLength           ds.b        1                         ; length of format String
  1003. fVersion          ds.b        1                         ; version number
  1004. data            ds.b        254                        ; private data                                <33>
  1005.                   endr
  1006.  
  1007. ;Number format equates
  1008.  
  1009. tokLeftQuote      EQU         1
  1010. tokRightQuote     EQU         2
  1011. tokLeadPlacer     EQU         3
  1012. tokLeader         EQU         4
  1013. tokNonLeader      EQU         5
  1014. tokZeroLead       EQU         6
  1015. tokPercent        EQU         7
  1016. tokPlusSign       EQU         8
  1017. tokMinusSign      EQU         9
  1018. tokThousands      EQU         10
  1019. tokSeparator      EQU         12                        ; 11 is reserved
  1020. tokEscape         EQU         13
  1021. tokDecPoint       EQU         14
  1022. tokEPlus          EQU         15
  1023. tokEMinus         EQU         16
  1024. tokMaxSymbols     EQU         31
  1025.  
  1026. NumberParts       record      0,increment
  1027. version           ds.w        1                         ; integer
  1028. data              ds.w        tokMaxSymbols             ; ARRAY[tokLeftQuote..tokMaxSymbols] OF WideChar
  1029. pePlus            ds          WideCharArr               ; 64
  1030. peMinus           ds          WideCharArr               ; 86
  1031. peMinusPlus       ds          WideCharArr               ; 108
  1032. altNumTable       ds          WideCharArr               ; 130
  1033. reserved          ds.b        20
  1034. numberPartsSize   equ         *
  1035. curNumberPartsVersion equ     1
  1036.                   endr
  1037.  
  1038.  
  1039. FVector           record      0,increment
  1040. start             ds.w        1                         ; INTEGER
  1041. length            ds.w        1                         ; INTEGER
  1042.                   endr
  1043.  
  1044. TripleInt         record      0,increment
  1045. zzz1              ds          FVector
  1046. zzz2              ds          FVector
  1047. zzz3              ds          FVector
  1048.                   endr
  1049.  
  1050. ; -----------------------------------------------------------------------------
  1051. ; Record for FindScriptRun result
  1052. ; -----------------------------------------------------------------------------
  1053.  
  1054. ScriptRunStatus   record      0,increment
  1055. script            ds.b        1
  1056. variant           ds.b        1
  1057.                   endr
  1058.  
  1059. ; -----------------------------------------------------------------------------
  1060. ; Selectors and macros for the Script Manager trap call, _ScriptUtil
  1061. ; -----------------------------------------------------------------------------
  1062.  
  1063.                   Macro
  1064.                   DefSMgrRoutine &name,&selector,&argSize,&returnSize
  1065.                   sm&name:    equ &selector**$FFFF
  1066.                   smSel&name: equ (1<<31)++(&returnSize<<24)++(&argSize<<16)++sm&name
  1067.                   endm
  1068.  
  1069. ; Trap routine selectors: script manager 1.0
  1070.  
  1071. smFontScript      EQU         0
  1072. smIntlScript      EQU         2
  1073. smKybdScript      EQU         4
  1074. smFont2Script     EQU         6
  1075. smGetEnvirons     EQU         8
  1076. smSetEnvirons     EQU         10
  1077. smGetScript       EQU         12
  1078. smSetScript       EQU         14
  1079. smHighCall        EQU         smSetScript               ; boundary between script mgr & script systems
  1080. smCharByte        EQU         16
  1081. smCharType        EQU         18
  1082. smPixel2Char      EQU         20
  1083. smChar2Pixel      EQU         22
  1084. smTranslit        EQU         24
  1085. smFindWord        EQU         26
  1086. smHiliteText      EQU         28
  1087. smDrawJust        EQU         30
  1088. smMeasureJust     EQU         32
  1089. smParseTable      EQU         34
  1090.  
  1091. ; Full Trap routine selectors: script manager 1.0
  1092.  
  1093. ; format                     newBit  return/args
  1094. smSelFontScript        EQU     (1<<31)++($0200<<16)++smFontScript
  1095. smSelIntlScript        EQU     (1<<31)++($0200<<16)++smIntlScript
  1096. smSelKybdScript        EQU     (1<<31)++($0002<<16)++smKybdScript
  1097. smSelFont2Script    EQU     (1<<31)++($0202<<16)++smFont2Script
  1098. smSelGetEnvirons    EQU     (1<<31)++($0402<<16)++smGetEnvirons
  1099. smSelSetEnvirons    EQU     (1<<31)++($0206<<16)++smSetEnvirons
  1100. smSelGetScript        EQU     (1<<31)++($0404<<16)++smGetScript
  1101. smSelSetScript        EQU     (1<<31)++($0208<<16)++smSetScript
  1102. smSelCharType        EQU     (1<<31)++($0206<<16)++smCharType
  1103. smSelCharByte        EQU     (1<<31)++($0206<<16)++smCharByte
  1104. smSelPixel2Char        EQU     (1<<31)++($020E<<16)++smPixel2Char
  1105. smSelChar2Pixel        EQU     (1<<31)++($020C<<16)++smChar2Pixel
  1106. smSelTranslit        EQU     (1<<31)++($020E<<16)++smTranslit
  1107. smSelFindWord        EQU     (1<<31)++($0012<<16)++smFindWord
  1108. smSelHiliteText        EQU     (1<<31)++($000E<<16)++smHiliteText
  1109. smSelDrawJust        EQU     (1<<31)++($0008<<16)++smDrawJust
  1110. smSelMeasureJust    EQU     (1<<31)++($000C<<16)++smMeasureJust
  1111. smSelParseTable        EQU     (1<<31)++($0204<<16)++smParseTable
  1112.  
  1113. ; selectors for general script manager 2.0 routines
  1114.  
  1115.         DefSmgrRoutine StyledLineBreak, -2,28,2
  1116.         DefSmgrRoutine GetFormatOrder, -4,18,0
  1117.         DefSmgrRoutine IntlTokenize, -6,4,2
  1118.  
  1119.         DefSmgrRoutine InitDateCache, -8,4,2
  1120.         DefSmgrRoutine String2Date, -10,20,2
  1121.         DefSmgrRoutine String2Time, -12,20,2
  1122.  
  1123.         DefSmgrRoutine LongDate2Secs, -14,8,0
  1124.         DefSmgrRoutine LongSecs2Date, -16,8,0
  1125.         DefSmgrRoutine ToggleDate, -18,14,2
  1126.  
  1127.         DefSmgrRoutine Str2Format, -20,12,2
  1128.         DefSmgrRoutine Format2Str, -22,16,2
  1129.         DefSmgrRoutine FormatX2Str, -24,16,2
  1130.         DefSmgrRoutine FormatStr2X, -26,16,2
  1131.         DefSmgrRoutine ValidDate, -28,12,2
  1132.  
  1133. ; selectors for script-specific script manager 2.0 routines
  1134.  
  1135.         DefSmgrRoutine PortionText, 36,8,4
  1136.         DefSmgrRoutine FindScriptRun, 38,12,2
  1137.         DefSmgrRoutine VisibleLength, 40,8,4
  1138.         DefSmgrRoutine IsSpecialFont, 42,2,2        ; implemented only by two-byte scripts
  1139.         DefSmgrRoutine RawPrinterValues, 44,22,2    ; implemented only by two-byte scripts
  1140.  
  1141. ; selectors for general script manager 7.0 routines                                        <2.1><2.4>
  1142.  
  1143.         DefSmgrRoutine    NFindWord,        -30,18,0    ; smSel… = $8012FFE2                <2.3>
  1144.         DefSmgrRoutine    TruncString,    -32,8,2        ; smSel… = $8208FFE0                <2.3><2.7><6>
  1145.         DefSmgrRoutine    TruncText,        -34,12,2    ; smSel… = $820CFFDE                <2.3><2.7><6>
  1146.         DefSmgrRoutine    ReplaceText,    -36,12,2    ; smSel… = $820CFFDC                <2.3>
  1147.  
  1148. ; selectors for script-specific script manager 7.0 routines                                <2>
  1149.  
  1150.         DefSmgrRoutine    NPixel2Char,    46,34,2        ;     $8222002E                        <2><17>
  1151.         DefSmgrRoutine    NChar2Pixel,    48,28,2        ;     $821C0030                        <2><17>
  1152.         DefSmgrRoutine    NDrawJust,        50,22,0        ;     $80160032                        <2><17>
  1153.         DefSmgrRoutine    NMeasureJust,    52,26,0        ;     $801A0034                        <2><17>
  1154.         DefSmgrRoutine    NPortionText,    54,18,4        ;     $84120036                        <2><17>
  1155.         
  1156. ; selectors for general script manager 7.1 routines                                        <2.1><2.4>
  1157.  
  1158.         DefSmgrRoutine    SCLwrString, -74,10,0        ; smSel… = $800AFFB6                <50>
  1159.  
  1160. ; function codes for SCLwrString                                                        <50>
  1161. sclwrDoLower        equ        $0000    ; where these bits go in _LowerText                    <50>
  1162. sclwrDoStrip        equ        $0200    ; where these bits go in _StripText                    <50>
  1163. sclwrDoUpper        equ        $0400    ; where these bits go in _UpperText                    <50>
  1164. sclwrDoStripUpper    equ        $0600    ; where these bits go in _StripUpperText            <50>
  1165.  
  1166. ; selectors for script-specific script manager 7.1 routines                                <43>
  1167.  
  1168.         DefSmgrRoutine    GetScriptRoutineAddr, 56,  4, 4    ; $84040038 implemented only by one-byte scripts
  1169.         DefSmgrRoutine    SetScriptRoutineAddr, 58,  8, 0    ; $8008003A implemented only by one-byte scripts
  1170.         DefSmgrRoutine    GetQDPatchAddr,          60,  6, 4    ; $8406003C implemented only by one-byte scripts
  1171.         DefSmgrRoutine    SetQDPatchAddr,          62, 10, 0    ; $800A003E implemented only by one-byte scripts
  1172.  
  1173. smSelSCGetScriptRoutineAddr    EQU        (1<<30)++smSelGetScriptRoutineAddr    ;                <43>
  1174. smSelSCSetScriptRoutineAddr    EQU        (1<<30)++smSelSetScriptRoutineAddr    ;                <43>
  1175. smSelSCGetQDPatchAddr        EQU        (1<<30)++smSelGetQDPatchAddr        ;                <43>
  1176. smSelSCSetQDPatchAddr        EQU        (1<<30)++smSelSetQDPatchAddr        ;                <43>
  1177.  
  1178. ; moved definition of sisHighCall and fisHighCall to ScriptPriv.a                         <2>
  1179.  
  1180. smSelSCCharByte                EQU        (1<<30)++smSelCharByte            ;                    <50>
  1181. smSelSCCharType                EQU        (1<<30)++smSelCharType            ;                    <50>
  1182. smSelSCTranslit                EQU        (1<<30)++smSelTranslit            ;                    <50>
  1183. smSelSCFindWord                EQU        (1<<30)++smSelFindWord            ;                    <50>
  1184. smSelSCParseTable            EQU        (1<<30)++smSelParseTable        ;                    <50>
  1185.  
  1186.  
  1187. ;------------------------------------------------------------------------------
  1188. ; Trap routine macros: Script Manager 1.0
  1189.  
  1190.                   macro
  1191.                   _FontScript
  1192.                   move.l      #smSelFontScript,-(sp)
  1193.                   _ScriptUtil
  1194.                   endm
  1195.  
  1196.                   macro
  1197.                   _IntlScript
  1198.                   move.l      #smSelIntlScript,-(sp)
  1199.                   _ScriptUtil
  1200.                   endm
  1201.  
  1202.                   macro
  1203.                   _KeyScript
  1204.                   move.l      #smSelKybdScript,-(sp)
  1205.                   _ScriptUtil
  1206.                   endm
  1207.  
  1208.                   macro
  1209.                   _Font2Script
  1210.                   move.l      #smSelFont2Script,-(sp)
  1211.                   _ScriptUtil
  1212.                   endm
  1213.  
  1214.                   macro
  1215.                   _GetEnvirons
  1216.                   move.l      #smSelGetEnvirons,-(sp)
  1217.                   _ScriptUtil
  1218.                   endm
  1219.  
  1220.                   macro
  1221.                   _SetEnvirons
  1222.                   move.l      #smSelSetEnvirons,-(sp)
  1223.                   _ScriptUtil
  1224.                   endm
  1225.  
  1226.                   macro
  1227.                   _GetScript
  1228.                   move.l      #smSelGetScript,-(sp)
  1229.                   _ScriptUtil
  1230.                   endm
  1231.  
  1232.                   macro
  1233.                   _SetScript
  1234.                   move.l      #smSelSetScript,-(sp)
  1235.                   _ScriptUtil
  1236.                   endm
  1237.  
  1238.                   macro
  1239.                   _CharByte
  1240.                   move.l      #smSelCharByte,-(sp)
  1241.                   _ScriptUtil
  1242.                   endm
  1243.  
  1244.                   macro
  1245.                   _CharType
  1246.                   move.l      #smSelCharType,-(sp)
  1247.                   _ScriptUtil
  1248.                   endm
  1249.  
  1250.                   macro
  1251.                   _Pixel2Char
  1252.                   move.l      #smSelPixel2Char,-(sp)
  1253.                   _ScriptUtil
  1254.                   endm
  1255.  
  1256.                   macro
  1257.                   _Char2Pixel
  1258.                   move.l      #smSelChar2Pixel,-(sp)
  1259.                   _ScriptUtil
  1260.                   endm
  1261.  
  1262.                   macro
  1263.                   _Transliterate
  1264.                   move.l      #smSelTranslit,-(sp)
  1265.                   _ScriptUtil
  1266.                   endm
  1267.  
  1268.                   macro
  1269.                   _FindWord
  1270.                   move.l      #smSelFindWord,-(sp)
  1271.                   _ScriptUtil
  1272.                   endm
  1273.  
  1274.                   macro
  1275.                   _HiliteText
  1276.                   move.l      #smSelHiliteText,-(sp)
  1277.                   _ScriptUtil
  1278.                   endm
  1279.  
  1280.                   macro
  1281.                   _DrawJust
  1282.                   move.l      #smSelDrawJust,-(sp)
  1283.                   _ScriptUtil
  1284.                   endm
  1285.  
  1286.                   macro
  1287.                   _MeasureJust
  1288.                   move.l      #smSelMeasureJust,-(sp)
  1289.                   _ScriptUtil
  1290.                   endm
  1291.  
  1292.                   macro
  1293.                   _ParseTable
  1294.                   move.l      #smSelParseTable,-(sp)
  1295.                   _ScriptUtil
  1296.                   endm
  1297.  
  1298. ;------------------------------------------------------------------------------
  1299. ; Trap routine macros: Script Manager 2.0
  1300.  
  1301.                   macro
  1302.                   _GetFormatOrder
  1303.                   move.l      #smSelGetFormatOrder,-(sp)
  1304.                   _ScriptUtil
  1305.                   endm
  1306.  
  1307.                   macro
  1308.                   _StyledLineBreak
  1309.                   move.l      #smSelStyledLineBreak,-(sp)
  1310.                   _ScriptUtil
  1311.                   endm
  1312.  
  1313.                   macro
  1314.                   _IntlTokenize
  1315.                   move.l      #smSelIntlTokenize,-(sp)
  1316.                   _ScriptUtil
  1317.                   endm
  1318.  
  1319.                   macro
  1320.                   _InitDateCache
  1321.                   move.l      #smSelInitDateCache,-(sp)
  1322.                   _ScriptUtil
  1323.                   endm
  1324.  
  1325.                   macro
  1326.                   _String2Date
  1327.                   move.l      #smSelString2Date,-(sp)
  1328.                   _ScriptUtil
  1329.                   endm
  1330.  
  1331.                   macro
  1332.                   _String2Time
  1333.                   move.l      #smSelString2Time,-(sp)
  1334.                   _ScriptUtil
  1335.                   endm
  1336.  
  1337.                   macro
  1338.                   _LongSecs2Date
  1339.                   move.l      #smSelLongSecs2Date,-(sp)
  1340.                   _ScriptUtil
  1341.                   endm
  1342.  
  1343.                   macro
  1344.                   _LongDate2Secs
  1345.                   move.l      #smSelLongDate2Secs,-(sp)
  1346.                   _ScriptUtil
  1347.                   endm
  1348.  
  1349.                   macro
  1350.                   _Str2Format
  1351.                   move.l      #smSelStr2Format,-(sp)
  1352.                   _ScriptUtil
  1353.                   endm
  1354.  
  1355.                   macro
  1356.                   _Format2Str
  1357.                   move.l      #smSelFormat2Str,-(sp)
  1358.                   _ScriptUtil
  1359.                   endm
  1360.  
  1361.                   macro
  1362.                   _FormatX2Str
  1363.                   move.l      #smSelFormatX2Str,-(sp)
  1364.                   _ScriptUtil
  1365.                   endm
  1366.  
  1367.                   macro
  1368.                   _FormatStr2X
  1369.                   move.l      #smSelFormatStr2X,-(sp)
  1370.                   _ScriptUtil
  1371.                   endm
  1372.  
  1373.                   macro
  1374.                   _ValidDate
  1375.                   move.l      #smSelValidDate,-(sp)
  1376.                   _ScriptUtil
  1377.                   endm
  1378.  
  1379.                   macro
  1380.                   _ToggleDate
  1381.                   move.l      #smSelToggleDate,-(sp)
  1382.                   _ScriptUtil
  1383.                   endm
  1384.  
  1385.                   macro
  1386.                   _PortionText
  1387.                   move.l      #smSelPortionText,-(sp)
  1388.                   _ScriptUtil
  1389.                   endm
  1390.  
  1391.                   macro
  1392.                   _FindScriptRun
  1393.                   move.l      #smSelFindScriptRun,-(sp)
  1394.                   _ScriptUtil
  1395.                   endm
  1396.  
  1397.                   macro
  1398.                   _ReadLocation
  1399.                   movea.l     (sp)+,A0
  1400.                   move.l      #$000C00E4,D0
  1401.                   _ReadXPRam
  1402.                   endm
  1403.  
  1404.                   macro
  1405.                   _WriteLocation
  1406.                   movea.l     (sp)+,A0
  1407.                   move.l      #$000C00E4,D0
  1408.                   _WriteXPRam
  1409.                   endm
  1410.  
  1411.                   macro
  1412.                   _VisibleLength
  1413.                   move.l      #smSelVisibleLength,-(sp)
  1414.                   _ScriptUtil
  1415.                   endm
  1416.  
  1417.                   macro
  1418.                   _IsSpecialFont
  1419.                   move.l      #smSelIsSpecialFont,-(sp)
  1420.                   _ScriptUtil
  1421.                   endm
  1422.  
  1423.                   macro
  1424.                   _RawPrinterValues
  1425.                   move.l      #smSelRawPrinterValues,-(sp)
  1426.                   _ScriptUtil
  1427.                   endm
  1428.  
  1429.  
  1430. ;------------------------------------------------------------------------------
  1431. ; Trap routine macros: Script Manager 7.0                    <2.1>
  1432.  
  1433.                 macro
  1434.                 _NFindWord                                    ; <2.3>
  1435.                 move.l      #smSelNFindWord,-(sp)
  1436.                 _ScriptUtil
  1437.                 endm
  1438.         
  1439.                 macro
  1440.                 _TruncString                                ; <2.3>
  1441.                 move.l      #smSelTruncString,-(sp)
  1442.                 _ScriptUtil
  1443.                 endm
  1444.         
  1445.                 macro
  1446.                 _TruncText                                    ; <2.3>
  1447.                 move.l      #smSelTruncText,-(sp)
  1448.                 _ScriptUtil
  1449.                 endm
  1450.         
  1451.                 macro
  1452.                 _ReplaceText                                ; <2.3>
  1453.                 move.l      #smSelReplaceText,-(sp)
  1454.                 _ScriptUtil
  1455.                 endm
  1456.         
  1457.                 macro
  1458.                 _NPixel2Char                                ;    <2>
  1459.                 move.l      #smSelNPixel2Char,-(sp)
  1460.                 _ScriptUtil
  1461.                 endm
  1462.         
  1463.                 macro
  1464.                 _NChar2Pixel                                ;    <2>
  1465.                 move.l      #smSelNChar2Pixel,-(sp)
  1466.                 _ScriptUtil
  1467.                 endm
  1468.         
  1469.                 macro
  1470.                 _NDrawJust                                    ;    <2>
  1471.                 move.l      #smSelNDrawJust,-(sp)
  1472.                 _ScriptUtil
  1473.                 endm
  1474.         
  1475.                 macro
  1476.                 _NMeasureJust                                ;    <2>
  1477.                 move.l      #smSelNMeasureJust,-(sp)
  1478.                 _ScriptUtil
  1479.                 endm
  1480.         
  1481.                 macro
  1482.                 _NPortionText                                ;    <2>
  1483.                   move.l      #smSelNPortionText,-(sp)
  1484.                   _ScriptUtil
  1485.                   endm
  1486.  
  1487. ;------------------------------------------------------------------------------
  1488. ; Trap routine macros: Script Manager 7.1                                        <43>
  1489.  
  1490.                 macro
  1491.                 _SCGetScriptRoutineAddr                            ;                <43>
  1492.                   move.l      #smSelSCGetScriptRoutineAddr,-(sp)
  1493.                   _ScriptUtil
  1494.                   endm
  1495.  
  1496.                 macro
  1497.                 _SCSetScriptRoutineAddr                            ;                <43>
  1498.                   move.l      #smSelSCSetScriptRoutineAddr,-(sp)
  1499.                   _ScriptUtil
  1500.                   endm
  1501.  
  1502.                 macro
  1503.                 _SCGetQDPatchAddr                                ;                <43>
  1504.                   move.l      #smSelSCGetQDPatchAddr,-(sp)
  1505.                   _ScriptUtil
  1506.                   endm
  1507.  
  1508.                 macro
  1509.                 _SCSetQDPatchAddr                                ;                <43>
  1510.                   move.l      #smSelSCSetQDPatchAddr,-(sp)
  1511.                   _ScriptUtil
  1512.                   endm
  1513.             
  1514.                 macro
  1515.                 _SCLowerText                                ;                    <50>
  1516.                 move.w        #sclwrDoLower,-(sp)
  1517.                 move.l      #smSelSCLwrString,-(sp)
  1518.                 _ScriptUtil
  1519.                 endm
  1520.         
  1521.                 macro
  1522.                 _SCStripText                                ;                    <50>
  1523.                 move.w        #sclwrDoStrip,-(sp)
  1524.                 move.l      #smSelSCLwrString,-(sp)
  1525.                 _ScriptUtil
  1526.                 endm
  1527.         
  1528.                 macro
  1529.                 _SCUpperText                                ;                    <50>
  1530.                 move.w        #sclwrDoUpper,-(sp)
  1531.                 move.l      #smSelSCLwrString,-(sp)
  1532.                 _ScriptUtil
  1533.                 endm
  1534.         
  1535.                 macro
  1536.                 _SCStripUpperText                            ;                    <50>
  1537.                 move.w        #sclwrDoStripUpper,-(sp)
  1538.                 move.l      #smSelSCLwrString,-(sp)
  1539.                 _ScriptUtil
  1540.                 endm
  1541.  
  1542.                   macro
  1543.                   _SCCharByte                                    ;                    <50>
  1544.                   move.l      #smSelSCCharByte,-(sp)
  1545.                   _ScriptUtil
  1546.                   endm
  1547.  
  1548.                   macro
  1549.                   _SCCharType                                    ;                    <50>
  1550.                   move.l      #smSelSCCharType,-(sp)
  1551.                   _ScriptUtil
  1552.                   endm
  1553.  
  1554.                   macro
  1555.                   _SCTransliterate                            ;                    <50>
  1556.                   move.l      #smSelSCTranslit,-(sp)
  1557.                   _ScriptUtil
  1558.                   endm
  1559.  
  1560.                   macro
  1561.                   _SCFindWord                                    ;                    <50>
  1562.                   move.l      #smSelSCFindWord,-(sp)
  1563.                   _ScriptUtil
  1564.                   endm
  1565.  
  1566.                   macro
  1567.                   _SCParseTable                                ;                    <50>
  1568.                   move.l      #smSelSCParseTable,-(sp)
  1569.                   _ScriptUtil
  1570.                   endm
  1571.  
  1572.     ENDIF    ; ...already included